var angular = require('angular');
var routes = require('./routes/auth.routes');
var navbarConfig = require('./config/navbar.config');

var orderService = require('./services/order.service');
var addrService = require('./services/addr.service');

var addrsController = require('./controllers/addrs.controller');
var orderListController = require('./controllers/orderlist.controller');
var orderController = require('./controllers/order.controller');
var payController = require('./controllers/pay.controller');

const moduleName = 'auth';

angular.module(moduleName, [])
    .config(routes)
    .factory('orderService',orderService)
    .factory('addrService',addrService)
    .controller('addrsController',addrsController)
    .controller('orderListController',orderListController)
    .controller('orderController',orderController)
    .controller('payController',payController)
    .run(navbarConfig);

module.exports = moduleName;